<?php
Yii::import('Cms.components.widgets.PureHtml');
class MarkupCode extends PureHtml
{
    /**
    * The url of page to create a new widget instance
    * 
    * @param array $params additional parameter to add to url's querystring
    * @return string
    */
    public function getCreateUrl($params = array()) {
        $className = 'PureHtml';
        $params['class'] = get_class($this);
        $route = '/'.$this->getModuleId().'/widgets/'.$className.'/create';
        return url($route, $params);
    }
        
    // return the url to edit text content
    public function getEditUrl($params = array()){
        $params['page_widget_id'] = $this->pageWidgetId;
        $params['id'] = $this->dataSettings['params'][':id'];
        $params['class'] = get_class($this);
        
        return url('/Cms/widgets/pureHtml/update', $params);
    }
}